<?php

/*
	Class: Commerce_Db_Table

	About: Author
		Rich Joslin

	About: License
		<http://communit.as/docs/license>

	About: See Also
		- <Cts_Db_Table_Abstract>
		- Zend_Db_Table
*/
abstract class Commerce_Db_Table extends Cts_Db_Table_Abstract {

	/* Group: Constructors */

	/*
		Constructor: Commerce_Db_Table
			Sets the locale code and calls the parent's constructor.

		Arguments:
			config (optional) - TBD
	*/
    function Commerce_Db_Table($locale_code, $config = null) {
		$this->locale_code = $locale_code;
    	return parent::__construct($config);
    }

	/* Group: Instance Methods */

	/*
		Function: _T
	*/
	protected function _T($key, $replace = null) {
		// IMPORTANT NOTE:
		// EVERY module must override this method in order to inject the correct module name
		return Cts_Translate($this->locale_code, "commerce", $key, $replace);
	}

}
